package initialization

import (
	"fmt"
	"github.com/spf13/viper"
)

type Nacos struct {
	DataId string
	Group  string
	Name   string
	Host   string
}

type Config struct {
	Nacos
}

var NacosConfig Config

func ConfigInit() {
	viper.SetConfigFile("../dev.yaml")
	viper.ReadInConfig()
	viper.Unmarshal(&NacosConfig)
	fmt.Println("配置文件设置成功", NacosConfig)
}
